import Home from '../page/Home'

import homePage from '../page/homePage'
import Shop from '../page/Shop'
import Coupe from '../page/Coupe'
import My from '../page/My'

import Login from '../page/Login'
import shopDetail from '../page/shopDetail'
import Department from '../page/Department'
import DepartDetail from '../page/DepartDetail'
import Car from '../page/Car'
import Record from '../page/Record'
import Doctor from '../page/Doctor'
import Pay from '../page/Pay'


const routes = [
    {
        from: '/',
        to: '/home'
    },
    {
        path: '/home',
        component: Home,
        children: [
            {
                from: '/home',
                to: '/home/homePage'
            },
            {
                path: '/home/homePage',
                component: homePage
            },
            {
                path: '/home/shop',
                component: Shop
            },
            {
                path: '/home/coupe',
                component: Coupe
            },
            {
                path: '/home/my',
                component: My
            },
        ]
    },
    {
        path: '/login',
        component: Login
    },
    {
        path: '/shopDetail/:id',
        component: shopDetail
    },
    {
        path: '/department',
        component: Department
    },
    {
        path: '/departDetail',
        component: DepartDetail
    },
    {
        path: '/car',
        component: Car
    },
    {
        path: '/record',
        component: Record
    },
    {
        path: '/doctor',
        component: Doctor
    },
    {
        path: '/pay',
        component: Pay
    }
]

export default routes